home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MacWorld 1997 February
/
Macworld (1997-02).dmg
/
Shareware World
/
Info
/
csmp digest Vol 4 No 024
< prev
next >
Wrap
Text File
|
1996-11-19
|
96KB
|
2,847 lines
C.S.M.P. Digest Tue, 19 Nov 96 Volume 4 : Issue 24
Today's Topics:
Amount ram for dev 8500?
AppleScript Commands
FindAllResIDsInFileGivenResourceType() ???
Floating Windoids in System 7.5
Help needed to create Mac files on a PC
Help!!! Welcome to Macintosh
Help: endian conversuin
How common is 512 x 342 max res?
ML for macintosh?
Q: how do I crop and then resave a PICT file?
ResEdit 'TMPL' question
Symantec C++ going away?
Texteditor needed w- AppleScript
Writing ioCompletion routine for Device Manager
[Q] Cross platform Development (Mac-Windows)...
[Q] Is there a function like GetDirContent()?
[Q] why can't I write a short?
displaying a pixmap on screen
resedit & PICT resources: help
The Comp.Sys.Mac.Programmer Digest is moderated by Mark Aiken
(marka@ee.mcgill.ca).
The digest is a collection of article threads from the internet
newsgroups comp.sys.mac.programmer.help, csmp.tools, csmp.misc and
csmp.games. It is designed for people who read news semi-regularly and
want an archive of the discussions. If you don't know what a
newsgroup is, you probably don't have access to it. Ask your systems
administrator(s) for details. If you don't have access to news, you
may still be able to post messages to the group by using a mail server
like anon.penet.fi (mail help@anon.penet.fi for more information).
Each issue of the digest contains one or more sets of articles (called
threads), with each set corresponding to a 'discussion' of a particular
subject. The articles are not edited; all articles included in this digest
are in their original posted form (as received by our news server at
ee.mcgill.ca). Article threads are not added to the digest until the last
article added to the thread is at least two weeks old (this is to ensure that
the thread is dead before adding it to the digest). Article threads that
consist of only one message are generally not included in the digest.
The digests can be obtained by email, ftp or through the World Wide Web.
If you want to receive the digest by mail, send email to
majordomo@ee.mcgill.ca with no subject and one of the following commands
as body:
help Sends you a summary of commands
subscribe csmp Adds you to the mailing list
unsubscribe csmp Removes you from the list
Once you have subscribed, you will automatically receive each new
issue as it is created.
Back issues are available by ftp from Info-Mac mirror sites in the
per/csmp subdirectory, e.g.
ftp://sumex-aim.stanford.edu/info-mac/per/csmp/
The contents of all back issues can be searched by accessing the
following URL, courtesy of Andrew Barry (ajbarry@ozemail.com.au):
http://marvin.stattech.com.au/search.html
They can also be searched through the following URLs, thanks to
Tim Tuck (Tim.Tuck@sensei.com.au):
http://wais.sensei.com.au/searchform.html
wais://wais.sensei.com.au:210/csmp?
-------------------------------------------------------
>From David Scott <dscott@west.net>
Subject: Amount ram for dev 8500?
Date: Tue, 22 Oct 1996 13:53:52 +0000
Organization: West.Net Communications
I just ordered a new 8500 and would like to get some suggestions about
the amount of ram to install. I'll only be using this machine for
development purposes.
Thank you.
--
David Scott
Santa Barbara
+++++++++++++++++++++++++++
>From Online@MacTech.com ( nick.c @MT )
Date: Thu, 24 Oct 1996 13:29:02 -0700
Organization: MacTech Magazine
In article <326CD1F0.49D@west.net>, dscott@west.net wrote:
>I just ordered a new 8500 and would like to get some suggestions about
>the amount of ram to install. I'll only be using this machine for
>development purposes.
Off the top of my head, 32 MB should be comfortable. You could
probably live with 24 MB, more is better.
____Nicholas C. DeMello, Ph.D.___________________________________________
"MacTech Online"--MacTech Magazine, for Mac OS Programmers and Developers
http://www.MacTech.com/
_/ _/ _/ _/_/_/ _/ _/
Chemistry: Nick@chem.UCLA.edu _/_/ _/ _/ _/ _/ _/_/_/
MacTech: Online@MacTech.com _/ _/_/ _/ _/ _/ _/
http://www.chem.ucla.edu/~nick/ _/ _/ _/_/_/ _/ _/
+++++++++++++++++++++++++++
>From gchapman@irus.rri.uwo.ca (Greg Chapman)
Date: Thu, 24 Oct 1996 10:32:12 -0500
Organization: Robarts Research Institute
In article <326CD1F0.49D@west.net>, dscott@west.net wrote:
> I just ordered a new 8500 and would like to get some suggestions about
> the amount of ram to install. I'll only be using this machine for
> development purposes.
I have 96 MB...
But I program for medical imaging, so your milage may vary. :)
--
Greg Chapman
Mac Developer - Robarts Research Institute
Imaging Research Labs
- -
"You! Out of the gene pool!"
+++++++++++++++++++++++++++
>From doverton@iglou.com (Dave Overton)
Date: 24 Oct 1996 13:02:05 GMT
Organization: NETCOM Network Operations
I have 48 MBytes in a Power Computing box and am just as happy as a clam.
Dave Overton
In article <326CD1F0.49D@west.net>, dscott@west.net wrote:
> I just ordered a new 8500 and would like to get some suggestions about
> the amount of ram to install. I'll only be using this machine for
> development purposes.
>
> Thank you.
> --
>
> David Scott
> Santa Barbara
+++++++++++++++++++++++++++
>From han@lava.net (Byron Han)
Date: 25 Oct 1996 08:58:03 -1000
Organization: LavaNet, Inc.
For me and my 9500, I give CodeWarrior 5 meg, MPW 10 meg, Netscape 3 meg,
Apple Telecom 5 meg, OpenDoc ... I have 48 meg and am a bit cramped.
Probably 64 meg or more is nice and roomy. If you want to do any
serious QuickTime/QuickTime VR authoring, you will want 96 meg to be
nice and speedy. With large amounts of RAM, it is also possible to
create a big RAM-disk where temp files for builds can be placed (in MPW)_
which can REALLY speed up builds. YMMV.
--
Byron Han * <http://www.hanchenson.com/~han> * <mailto:han@hanchenson.com>
Han Chen & Son - MacOS Software Development * PO Box 61557 * Honolulu HI 96839
"Windows 95 - Can't Get No Satisfaction"
+++++++++++++++++++++++++++
>From smfr@santafe.edu (Simon Fraser)
Date: 4 Nov 1996 21:13:57 GMT
Organization: Santa Fe Institute
In article <ucs-ya023180000411961029460001@199.2.194.10>, dscott@west.net wrote:
>24 Megs at minimum. Forget using RAM Doubler if you're trying to debug
>anything other than applications that do not patch the OS. Its not worth
>the trouble.
I would say that 32Mb is minimum. Some debugging tools require VM
and / or Ram Doubler to be off, which, if you are doing Speech Recog
or something, puts the System heap at around the 12MB mark. Then have
open your compiler, debugger, Netscape (to browse Inside Mac online),
and ResEdit, and you've run out.
BTW, I code and debug with RD installed with no problems. Just turn
it off to find those really pesky bugs with the serious debugging tools!
Simon
+++++++++++++++++++++++++++
>From ucs@europa.com (ucs)
Date: Mon, 04 Nov 1996 10:29:46 -0800
Organization: Universal Computing Systems
24 Megs at minimum. Forget using RAM Doubler if you're trying to debug
anything other than applications that do not patch the OS. Its not worth
the trouble.
My rec. for memory is is along the lines of 1950's consumerism- more is better.
--
Saying Dole is Better Than Clinton is no different that saying the Son of
Sam is better than the Hillside Strangler.
+++++++++++++++++++++++++++
>From "Thomas L. Ferrell" <ferrelltl@ornl.gov>
Date: 5 Nov 1996 02:31:13 GMT
Organization: Oak Ridge National Lab
I use every bit of 48 Mb of RAM since I have a lot of image processing
going on in my programming. This is for scientific work,but might be
important for games also--it just depends on your own needs,but as cheap
as RAM is, I see no need to minimize on such an important enhancement.
tom
---------------------------
>From cokin@primenet.com (Darren Cokin)
Subject: AppleScript Commands
Date: 4 Nov 1996 19:39:04 -0700
Organization: Primenet Services for the Internet
I'm trying to accomplish a lofty automation task, mostly in MiniPascal,
MiniCad's internal programming/scripting language. That all works just
fine. But for some of what I want to do, I need AppleScript, but I can't
find any documentation, and I'm in kind of a hurry here. What I want to
do isn't really all that complex either.
I figured out how to "tell" MiniCad to open a certain file, signal it to
make the necessary changes, and even to send a "Print..." command. But
not how to print 1 copy, or to close the file without saving changes.
"Print..." opens a dialog box, asking for the user to enter the number of
copies. The goal is to print a large number of files automatically, we
don't want to have to hit return every minute or so for 3 hours as this
thing runs. Is there a print 1 copy command, or a way to tell it to hit
"Ok" as soon as the print dialog comes up? What about closing the file,
without saving changes?
Anyone who could either tell me the commands and proper syntax I need, or
point me to an online reference source, would be most appreciated.
Thanks!
Darren
+++++++++++++++++++++++++++
>From peter@jlist.com (Peter Payne)
Date: Wed, 6 Nov 1996 02:28:40 +0900
Organization: Lobo Net
> Anyone who could either tell me the commands and proper syntax I need, or
> point me to an online reference source, would be most appreciated.
> Thanks!
>
Try
http://www.latenightsw.com/scripting.html
for some links. I would like a whole list of Applescript's commands
myself, but I couldn't find one.
*J-LIST* www.jlist.com Japanese | *SAKURA SOFT* www.sakurasoft.com
adult magazines, CD ROM, videos, | Interactive Japanese adult
Japanese pop music (JPOP), software, | fantasies for your PC. The best
much more. OVER 18 ONLY!! | from Japan to you. OVER 18 ONLY!!
+++++++++++++++++++++++++++
>From jimbarnes@gulf.net (Jim Barnes)
Date: Wed, 06 Nov 1996 22:34:19 -0600
Organization: Mostly none.
In article <19961106022840398981@[202.230.39.208]>, peter@jlist.com (Peter
Payne) wrote:
>> Anyone who could either tell me the commands and proper syntax I need, or
>> point me to an online reference source, would be most appreciated.
>> Thanks!
>
>Try
>
>http://www.latenightsw.com/scripting.html
>
>for some links. I would like a whole list of Applescript's commands
>myself, but I couldn't find one.
>
You probably can't find a complete list since the commands are all built
into each application that supports AppleScript. Danny Goodman's
_Applescript Handbook_ is probably the closest thing I know to a list of
commands.
There is a Required Suite of commands that each scriptable application
must support which contains the open print quit and run commands. This
print command *only* does exactly what selecting a file in the Finder and
choosing the Print command.
To get more functionality, the application must provide it. To find out
what commands an application supports, select "Open Dictionary..." from
the Script Editor's File menu and find the application. The list of
commands is broken down into groups or "Suites," which lists the syntax
for each command. Most of the time I find it difficult to understand
exactly how to use each command because there is no example listed with
the commands.
Hope that helps,
--
- -
Jim Barnes -- jimbarnes@gulf.net
---------------------------
>From heller@cs.umass.edu (Robert Heller)
Subject: FindAllResIDsInFileGivenResourceType() ???
Date: 4 Nov 1996 11:03:49 GMT
Organization: CMPSCI Department, UMass Amherst
I need to collect all of the in use resource IDs for a given resource
type in the resource fork of a file. The "brute force" method:
short curResFile = CurResFile();
UseResFile(refNum);
for (int ires = 0; ires < 32768; ires++)
{
Cell aCell;
Handle resource = Get1Resource(LabelTemplate::labelResourceType$
if (resource == NULL) continue;
Size s = GetHandleSize(resource);
DetachResource(resource);
DisposeHandle(resource);
/* some processing */
}
UseResFile(curResFile);
is obviously not the solution. There does not appear to be a function
that returns this information, at not that I can find. ResEdit (and
DeRez) obviously can do this, but what is the magic?
--
\/
Robert Heller ||InterNet: Heller@CS.UMass.EDU
http://vis-www.cs.umass.edu/~heller ||FidoNet: 1:321/153
http://netmar.com/mall/shops/heller /\
+++++++++++++++++++++++++++
>From bilewicz@helf4.physik.fu-berlin.de (Roger Bilewicz)
Date: 4 Nov 96 13:05:47 GMT
Organization: Freie Universitaet Berlin
heller@cs.umass.edu (Robert Heller) writes:
>I need to collect all of the in use resource IDs for a given resource
>type in the resource fork of a file. The "brute force" method:
> short curResFile = CurResFile();
> UseResFile(refNum);
> for (int ires = 0; ires < 32768; ires++)
> {
> Cell aCell;
> Handle resource = Get1Resource(LabelTemplate::labelResourceType$
> if (resource == NULL) continue;
> Size s = GetHandleSize(resource);
> DetachResource(resource);
> DisposeHandle(resource);
> /* some processing */
> }
> UseResFile(curResFile);
>is obviously not the solution. There does not appear to be a function
>that returns this information, at not that I can find. ResEdit (and
>DeRez) obviously can do this, but what is the magic?
Robert,
you can use CountResources / Count1Resources to get the number of
resources of a given type and then call GetIndResource / Get1IndResource
in a for-loop to read the resources by index.
These routines are documented in Inside Macintosh: More Macintosh Toolbox.
May it help,
Roger
+++++++++++++++++++++++++++
>From magao@zip.com.au (Timothy C. Delaney)
Date: Tue, 05 Nov 1996 08:26:19 +1100
Organization: The Zipsters
In article <55kiil$ic3@kernighan.cs.umass.edu>, heller@cs.umass.edu (Robert
Heller) wrote:
> I need to collect all of the in use resource IDs for a given resource
> type in the resource fork of a file. The "brute force" method:
Look for Count1Resources() and GetResInfo().
short numResources = Count1Resources('????');
Handle h;
short rsrcID,
ResType rsrcType;
Str255 rsrcName;
short index;
SetResLoad(false);
for (index = 1; index <= numResources; index++)
{
h = Get1IndResource('????', index);
GetResInfo(h, &rsrcID, &rsrcType, rsrcName);
/* do processing */
}
SetResLoad(true);
Two things to note:
The index starts at one (1), not zero (0).
By calling SetResLoad(false) the resource is not actually loaded into
memory - you only get a non-empty handle if it's already in memory. This
cuts down on the time taken.
--
<http://www.zip.com.au/~magao/standard_disclaimer.html>
_/_/_/_/
__| __| _/_| _/_/_/ _/_| _/_/_/
_/_| _/_| _/ _| _/ _/ _| _/ _/
-/ _|_/ _| _/_/_/_| _/ _/_/_/ _/_/_/_| _/ _/
_/ __/ _| _/ _| _/_/_/ _/ _| _/_/_/
Tim Delaney magao@zip.com.au
Mac/Windows SW Engineer, Bold magao@bold.com.au
---------------------------
>From hooty@odyssee.net (Eric Dorland)
Subject: Floating Windoids in System 7.5
Date: Fri, 01 Nov 1996 22:23:06 -0400
Organization: Odyssee Internet
Is there any technote or some piece of documentation on the floating
windoid capability in System 7.5?
Eric Dorland
hooty@odyssee.net
http://www.odyssee.net/~hooty/
+++++++++++++++++++++++++++
>From blob@ricochet.net
Date: Sat, 02 Nov 1996 11:22:53 -0800
Organization: (none)
In article <hooty-0111962223060001@news.odyssee.net>, hooty@odyssee.net
(Eric Dorland) wrote:
> Is there any technote or some piece of documentation on the floating
> windoid capability in System 7.5?
No. You're better off using the Infinity Windoid, available from any
info-mac archive such as <ftp://mirror.apple.com/mirrors/info-mac/dev/>
--
(Pointers to other Mac programming web sites at
<http://devworld.apple.com/dev/geeks.html>)
+++++++++++++++++++++++++++
>From Steve Makohin <WaterEdgSW@aol.com>
Date: 2 Nov 1996 22:17:04 GMT
Organization: Water's Edge Software
In article <hooty-0111962223060001@news.odyssee.net> Eric Dorland,
hooty@odyssee.net writes:
>Subject: Floating Windoids in System 7.5
>From: Eric Dorland, hooty@odyssee.net
>Date: Fri, 01 Nov 1996 22:23:06 -0400
>>Is there any technote or some piece of documentation on the floating
>windoid capability in System 7.5?
Only floating palette WDEF is included with System 7.5, that is you get
the _look_, but not the behavior of a floating palette. If your app will
run only on System 7.5 or later, you have a start, otherwise you'll need
to get a floating palette WDEF for pre-System 7.5 apps. The Infinity WDEF
is a good selection.
You have several options to make the window _behave_ like a floating
palette:
1. Use a class in Symantec's TCL
2. Use a class in Metowerks' PowerPlant
3. Use Tools Plus application development libraries
4. Roll your own code (not a good option)
5. Wait for MacOS 8
BTW, you can get a free evaluation kit of our Tools Plus libraries at our
web site, or just take an illustrated Tools Plus Guided Tour. Tools Plus
lets you create any *working* GUI element with 1 line code, including
tool bars, picture buttons, pop-up menus, etc. It also makes dialogs and
menus work with a single line of code. Rate 4 stars by Macworld magazine.
-Steve Makohin
Water's Edge Software
(Makers of Tools Plus & SuperCDEFs)
http://www.interlog.com/~wateredg
+++++++++++++++++++++++++++
>From dkj@apple.com (Dave Johnson)
Date: Wed, 06 Nov 1996 11:49:25 -0800
Organization: Apple Computer, Inc.
In article <55gh90$q17@news.interlog.com>, Steve Makohin
<WaterEdgSW@aol.com> wrote:
> In article <hooty-0111962223060001@news.odyssee.net> Eric Dorland,
> hooty@odyssee.net writes:
> >Subject: Floating Windoids in System 7.5
> >From: Eric Dorland, hooty@odyssee.net
> >Date: Fri, 01 Nov 1996 22:23:06 -0400
> >>Is there any technote or some piece of documentation on the floating
> >windoid capability in System 7.5?
>
> Only floating palette WDEF is included with System 7.5, that is you get
> the _look_, but not the behavior of a floating palette. If your app will
> run only on System 7.5 or later, you have a start, otherwise you'll need
> to get a floating palette WDEF for pre-System 7.5 apps. The Infinity WDEF
> is a good selection.
>
> You have several options to make the window _behave_ like a floating
> palette:
> 1. Use a class in Symantec's TCL
> 2. Use a class in Metowerks' PowerPlant
> 3. Use Tools Plus application development libraries
> 4. Roll your own code (not a good option)
> 5. Wait for MacOS 8
<snip>
There are two other floaters libraries he doesn't mention: one from
develop magazine issue 15, code rewritten a year or wo ago and now pretty
solid, and one from MacTech magazine as well.
Dave Johnson
---------------------------
>From "Marcus Mac Innes" <mmacinnes@vicorp.co.uk>
Subject: Help needed to create Mac files on a PC
Date: Fri, 04 Oct 1996 19:23:57 GMT
Organization: Vicorp UK
Hi there...
I'm currently running a PC system and have a need to send files to a Mac
using zmodem... I didn't reaslise that the Mac needs an 'extra' little bit
called the resource fork. To make matters worse, I don't have access to any
of the Macintosh machines I'm sending files to...
Does anyone know how I can create a graphic file using Photoshop on a PC
and 'alter' it in some way to so that I can send it to a Mac, WITHOUT
having to alter the file on the Mac itself (i.e. using resedit...)
It's really important that users on the Mac don't have to perform any
alterations to the file once they receive it. IT MUST look like it was
created on another Mac!
There has to be a little utility to do the job.
Anyone know if one exists....?
--
Regards,
Marcus Mac Innes
(Please e-mail any reponse.... Thank You...)
+++++++++++++++++++++++++++
>From nyamuk2@ix.netcom.com (HERO)
Date: Thu, 03 Oct 1996 18:26:57 -0800
Organization: HANUMAN EROS PT
Global village has just introduced a communications application for the
purpose you describe got to their website at: http://www.globalvillage.com
In article <01bbb229$59e984e0$c70cdec2@vicorp.demon.co.uk>, "Marcus Mac
Innes" <mmacinnes@vicorp.co.uk> wrote:
> Hi there...
>
> I'm currently running a PC system and have a need to send files to a Mac
> using zmodem... I didn't reaslise that the Mac needs an 'extra' little bit
> called the resource fork. To make matters worse, I don't have access to any
> of the Macintosh machines I'm sending files to...
>
> Does anyone know how I can create a graphic file using Photoshop on a PC
> and 'alter' it in some way to so that I can send it to a Mac, WITHOUT
> having to alter the file on the Mac itself (i.e. using resedit...)
>
> It's really important that users on the Mac don't have to perform any
> alterations to the file once they receive it. IT MUST look like it was
> created on another Mac!
>
> There has to be a little utility to do the job.
>
> Anyone know if one exists....?
>
> --
> Regards,
>
> Marcus Mac Innes
>
> (Please e-mail any reponse.... Thank You...)
+++++++++++++++++++++++++++
>From cougar@west.net (Cougar)
Date: Mon, 07 Oct 1996 06:21:21 -0800
Organization: West.Net Communications
In article <01bbb229$59e984e0$c70cdec2@vicorp.demon.co.uk>, "Marcus Mac
Innes" <mmacinnes@vicorp.co.uk> wrote:
> Hi there...
>
> I'm currently running a PC system and have a need to send files to a Mac
> using zmodem... I didn't reaslise that the Mac needs an 'extra' little bit
> called the resource fork. To make matters worse, I don't have access to any
> of the Macintosh machines I'm sending files to...
>
> Does anyone know how I can create a graphic file using Photoshop on a PC
> and 'alter' it in some way to so that I can send it to a Mac, WITHOUT
> having to alter the file on the Mac itself (i.e. using resedit...)
>
> It's really important that users on the Mac don't have to perform any
> alterations to the file once they receive it. IT MUST look like it was
> created on another Mac!
>
> There has to be a little utility to do the job.
You could try GlobalTransfer by Global Village.
--
http://www.west.net/~cougar
+++++++++++++++++++++++++++
>From george@mech.seas.upenn.edu ( George Jefferson )
Date: 7 Oct 1996 19:31:43 GMT
Organization: Mechanical Engineering
:I'm currently running a PC system and have a need to send files to a Mac
:using zmodem... I didn't reaslise that the Mac needs an 'extra' little bit
:called the resource fork. To make matters worse, I don't have access to any
:of the Macintosh machines I'm sending files to...
One way (easiest i think) is to do a raw binary transfer and
setup zterm on the mac to set the file type correctly,
thats all. There should be no resource fork to your graphics
files. If you really have no acess to the mac you have a tough
problem - if the user cant set the type how do you know he
doesn't have it in text mode for that matter.
Another way, maybe easier for the mac user, is to do a macbinary
transfer. Then on the pc end you need to prepend the macbinary
header to the graphic file before sending. I'd be suprised if
there isn't a little dos utility to do that (hunt your favorite
archive)
+++++++++++++++++++++++++++
>From mogge@eulines.hv.se (Morgan Ericsson)
Date: 7 Oct 1996 20:58:12 GMT
Organization: Solace Computer Society, Sundsvall
When will all you mac users understand that comp.os.mach isn't about macs? I
mean, why on earth do you think it's called mach? And the fact that other
mac groups are called comp.sys.mac.something, should make you think twice
before posting in a comp.os.something group.
(For all the people who still don't get it. Mach is a microkernel. Sure
there are ports of mach for macs (mklinux etc), but that doesn't mean that
we want stupid macintosh questions here...)
- -
Morgan Ericsson, LINES Project
Dept. of Mathematics, Statistics and Computer Science
Vaxjo University
+++++++++++++++++++++++++++
>From RCS@Backdoor.com (Russell Seymour)
Date: 8 Oct 96 06:47:39 GMT
Organization: The Denver Exchange, Inc. - http://www.tde.com/
In article <cougar-0710960621210001@term1-21.sb.west.net>, cougar@west.net
(Cougar) wrote:
->In article <01bbb229$59e984e0$c70cdec2@vicorp.demon.co.uk>, "Marcus Mac
->Innes" <mmacinnes@vicorp.co.uk> wrote:
->
->> Does anyone know how I can create a graphic file using Photoshop on a PC
->> and 'alter' it in some way to so that I can send it to a Mac, WITHOUT
->> having to alter the file on the Mac itself (i.e. using resedit...)
->>
-
I am not familiar with Photoshop, but they may have a SAVE AS.... option
to save it as a MAC file. MS-WORD for Windows has this option to save the
WORD file in several WORD versions for the MAC from 4.0 to 5.1....
+++++++++++++++++++++++++++
>From psyc394@csc.canterbury.ac.nz (Michael R. MacAskill)
Date: Fri, 18 Oct 1996 16:43:16 +1200
Organization: Christchurch Hospital / University of Otago
> ->
> ->> Does anyone know how I can create a graphic file using Photoshop on a PC
> ->> and 'alter' it in some way to so that I can send it to a Mac, WITHOUT
> ->> having to alter the file on the Mac itself (i.e. using resedit...)
Don't make things to hard for yourself. Don't send it as a Photoshop
file, but as one of the standard graphic formats (Tiff, bmp, etc) which
the Mac Photoshop will quite happily open without needing a resource fork.
> -
> I am not familiar with Photoshop, but they may have a SAVE AS.... option
> to save it as a MAC file. MS-WORD for Windows has this option to save the
> WORD file in several WORD versions for the MAC from 4.0 to 5.1....
Word 6.0 files are able to be read between the Mac and PC platforms
without any translation
Mike
\\ Michael R. MacAskill \\ \\
\\ Department of Medicine \\ Ph: +64 3 3640 640 \\
\\ Christchurch Hospital \\ ext 88138 or 88206 \\
\\ Private Bag 4710 \\ Fax: +64 3 3640 935 \\
\\ CHRISTCHURCH, NEW ZEALAND \\ \\
+++++++++++++++++++++++++++
>From northwind@earthlink.net (Karsten Jeppesen)
Date: Sun, 20 Oct 1996 05:29:36 GMT
Organization: Earthlink Network, Inc.
psyc394@csc.canterbury.ac.nz (Michael R. MacAskill) wrote:
>
>> ->
>> ->> Does anyone know how I can create a graphic file using Photoshop on a PC
>> ->> and 'alter' it in some way to so that I can send it to a Mac, WITHOUT
>> ->> having to alter the file on the Mac itself (i.e. using resedit...)
>
>Don't make things to hard for yourself. Don't send it as a Photoshop
>file, but as one of the standard graphic formats (Tiff, bmp, etc) which
>the Mac Photoshop will quite happily open without needing a resource fork.
AND remember that EPS although it exists on both platforms are
different in structure. There are programs that will convert but you
usually looses the preview.
Nice answer by the way.
>
>> -
>> I am not familiar with Photoshop, but they may have a SAVE AS.... option
>> to save it as a MAC file. MS-WORD for Windows has this option to save the
>> WORD file in several WORD versions for the MAC from 4.0 to 5.1....
>
>Word 6.0 files are able to be read between the Mac and PC platforms
>without any translation
>
>Mike
>
>\\ Michael R. MacAskill \\ \\
> \\ Department of Medicine \\ Ph: +64 3 3640 640 \\
> \\ Christchurch Hospital \\ ext 88138 or 88206 \\
> \\ Private Bag 4710 \\ Fax: +64 3 3640 935 \\
> \\ CHRISTCHURCH, NEW ZEALAND \\ \\
+++++++++++++++++++++++++++
>From "Victor J. Spadaro" <vspadaro@jdv.net>
Date: Fri, 25 Oct 1996 02:54:28 -0500
Organization: JDV Enterprises, Inc.
Save it as filename.gif then copy it to a floppy then insert the pc disk
into the mac and copy it to the hard drive and then open it in photoshop
for the mac. Simple do it all the time
--
**********************************************************************
Send E-Mail to:
mailto:vspadaro@jdv.net
http://www.jdv.net
Victor J. Spadaro
Executive Vice-President
JDV Enterprises, Inc.
709 13th Ave. So.
Clinton, IA. 52732 USA
(319) 243-6782 Voice
(319) 243-6683 Fax
NOTICE: I DO NOT ACCEPT UNSOLICITED COMMERCIAL EMAIL MESSAGES OF ANY
KIND. I
CONSIDER SUCH MESSAGES PERSONAL HARRASSMENT AND A GROSS INVASION OF MY
PRIVACY. By sending unsolicited commercial advertising/solicitations
(or
otherwise on or as part of a mailing list) to me via e-mail you will be
indicating your consent to paying Victor J. Spadaro $1,000.00
U.S.D./hour
for a minimum of 1 hour for my time spent dealing with it. Payment due
in 30
days upon receipt of an invoice (e-mail or regular mail) from me or my
authorized representative.
**********************************************************************
+++++++++++++++++++++++++++
>From "gmac63" <perigee.net>
Date: Sun, 27 Oct 1996 00:26:50 -0500
Organization: Zippo
In article <psyc394-1810961643160001@news.canterbury.ac.nz>,
psyc394@csc.canterbury.ac.nz (Michael R. MacAskill) wrote:
>Don't make things to hard for yourself. Don't send it as a Photoshop
>file, but as one of the standard graphic formats (Tiff, bmp, etc) which
>the Mac Photoshop will quite happily open without needing a resource fork.
>
I didn't think Photoshop had a problem with it's own format cross-platform.
i can see where the resource fork can be an issue in files such as .eps
or.qxd, but Photoshop?!? could it be that the inquirer is trying to copy a
file from the PC to a Mac via floppy? this can confuse the app of the Mac
into beleiveing that the file is just a "document". I have copied
Illustrator files in this manner and have used the .ai . Illustrator will
not see them as Illustrator files because they don't have the type and
creator.
However I can agree with you though, that the use of tiffs pr bmps may be
the best because I have had photoshop launch when double-clicked on.
PC Exchange may be helpful here also. It can be configured to recognize the
files by their extensions and rebuild their resource forks.
Wes Yates - gmac63@perigee.net
+++++++++++++++++++++++++++
>From thuerman@ibr.cs.tu-bs.de (Urs Thuermann)
Date: 28 Oct 1996 10:26:09 +0100
Organization: TU Braunschweig, Informatik (Bueltenweg), Germany
In article <32707207.387E@jdv.net> "Victor J. Spadaro"
<vspadaro@jdv.net> writes:
> Save it as filename.gif then copy it to a floppy then insert the pc disk
> into the mac and copy it to the hard drive and then open it in photoshop
> for the mac. Simple do it all the time
Please remove comp.os.mach from the newsgroup line when following up
to this thread. This is *NOT* a Macintosh group.
urs
+++++++++++++++++++++++++++
>From thuerman@ibr.cs.tu-bs.de (Urs Thuermann)
Date: 28 Oct 1996 10:39:53 +0100
Organization: TU Braunschweig, Informatik (Bueltenweg), Germany
In article <perigee.net-2710960026500001@206.229.254.97>
"gmac63" <perigee.net> writes:
> I didn't think Photoshop had a problem with it's own format cross-platform.
> i can see where the resource fork can be an issue in files such as .eps
> or.qxd, but Photoshop?!? could it be that the inquirer is trying to copy a
> file from the PC to a Mac via floppy? this can confuse the app of the Mac
> into beleiveing that the file is just a "document". I have copied
> Illustrator files in this manner and have used the .ai . Illustrator will
> not see them as Illustrator files because they don't have the type and
> creator.
Please remove comp.os.mach from the newsgroup line when following up
to this thread. This is *NOT* a Macintosh group.
urs
+++++++++++++++++++++++++++
>From brianl@media4.com (Brian Landwehr)
Date: Wed, 06 Nov 1996 04:06:05 GMT
Organization: Media4 Productions Inc.
MacDrive 95 will allow you to read and write nearly any kind of
Mac-format disk from Windows 95 and all software that runs under
Windows 95. It automatically generates file name extensions based on
type & creator when listing Mac files under Windows 95, and
automatically assigns type and creator based on file name extension
when Windows 95 software creates a file on a Mac disk.
For more information, email media4@media4.com or go to
http://www.media4.com.
Brian Landwehr
Media4 Productions Inc.
thuerman@ibr.cs.tu-bs.de (Urs Thuermann) wrote:
>In article <perigee.net-2710960026500001@206.229.254.97>
>"gmac63" <perigee.net> writes:
>> I didn't think Photoshop had a problem with it's own format cross-platform.
>> i can see where the resource fork can be an issue in files such as .eps
>> or.qxd, but Photoshop?!? could it be that the inquirer is trying to copy a
>> file from the PC to a Mac via floppy? this can confuse the app of the Mac
>> into beleiveing that the file is just a "document". I have copied
>> Illustrator files in this manner and have used the .ai . Illustrator will
>> not see them as Illustrator files because they don't have the type and
>> creator.
>Please remove comp.os.mach from the newsgroup line when following up
>to this thread. This is *NOT* a Macintosh group.
>urs
---------------------------
>From <JJACQU51@MAINE.MAINE.EDU>
Subject: Help!!! Welcome to Macintosh
Date: Tue, 29 Oct 1996 19:58:58 EST
Organization: University of Maine System
HI there, I have never really done any Mac programming but I would like to chan
ge the "welcome to Macintosh. Connectix Ram Doubler" opening box at startup to
a customized message..... can someone help me... or send advice, Thanks
jjacqu51@maine.maine.edu
+++++++++++++++++++++++++++
>From stian@mail.utexas.edu (Stian Oksavik)
Date: 3 Nov 1996 07:31:23 GMT
Organization: University of Texas at Austin
In article <microcsm-0211960147060001@news.goldinc.com>,
microcsm@goldinc.com (David Blache) wrote:
> In article <96303.195858JJACQU51@MAINE.MAINE.EDU>,
> <JJACQU51@MAINE.MAINE.EDU> wrote:
>
> > HI there, I have never really done any Mac programming but I would like
> to chan
> > ge the "welcome to Macintosh. Connectix Ram Doubler" opening box at
startup to
> > a customized message..... can someone help me... or send advice, Thanks
> > jjacqu51@maine.maine.edu
>
> The "Welcome to Macintosh" message is stored in one of the STR or STR#
> resources in the System file (if I remember correctly) . Good luck
> finding it though. There are thousands. I've kept a list of
> miscellaneous strings I've run across in the past; but that one isn't in
> my list.
[snip]
Actually, it's stored in a DSAT resource. And be careful modifying it; the
string must be the same length (or you must change the lengthy and pad or
remove bytes as necessary to keep the resource the same size and the
string at the same offset and not overwrite any other data.) A little
slipup will cause your Mac to crash at startup.
There are programs out there that will do this for you. I don't remember
the name of any of them, but someone else here surely does.
Also, the "Connectix Ram Doubler" string is RAMDoubler's doing. So you'll
have to come up with a separate hack for RAMDoubler.
-Stian
+++++++++++++++++++++++++++
>From AjayToo@ptdprolog.net (AjayToo)
Date: Sun, 03 Nov 1996 00:27:30 -0500
Organization: ProLog - PenTeleData, Inc.
In article <96303.195858JJACQU51@MAINE.MAINE.EDU>,
<JJACQU51@MAINE.MAINE.EDU> wrote:
> HI there, I have never really done any Mac programming but I would like
to chan
> ge the "welcome to Macintosh. Connectix Ram Doubler" opening box at startup to
> a customized message..... can someone help me... or send advice, Thanks
> jjacqu51@maine.maine.edu
You can replace that little phrase with one of your own, or with none at
all. Begin by making a backup copy of the RAM Doubler extension, which you
can do by option-dragging the original from the Extensions folder to the
Startup Disk icon. Then use Apple's ResEdit utility to open the original
RAM Doubler, and in the list of resource types that appears, double-click
the DSAT type. Open the only DSAT resource, ID -4064, to see its contents.
Then find the message on the right side of the resource-editing window,
select it, and type a replacement (see "RAM Doubler Start-up"). Save your
changes and restart the Mac to view your handiwork.
-AjayToo
+++++++++++++++++++++++++++
>From Yi Li <yili@cse.bridgeport.edu>
Date: Sun, 03 Nov 1996 15:25:15 -0500
Organization: UB
Hi,
I could grab a vedio frame by the code inclosed but I don't know how to
save it. I use QuicktimeLib, the compiler is codewarrior 10. The
function call I used are vedio digitizer components.
Could you help me to tell me what function am I supposed
to use? Sample code or simple algorithm are more than welcomed.
Thanks,
Y Lee
void MyNew()
{
ComponentInstance VThingInst;
...
//set all rectangle
GrabOneFrame(VThingInst);
}
+++++++++++++++++++++++++++
>From smfr@santafe.edu (Simon Fraser)
Date: Sat, 02 Nov 1996 14:38:04 -0700
Organization: Santa Fe Institute
In article <microcsm-0211960147060001@news.goldinc.com>,
microcsm@goldinc.com (David Blache) wrote:
> In article <96303.195858JJACQU51@MAINE.MAINE.EDU>,
> <JJACQU51@MAINE.MAINE.EDU> wrote:
>
> > HI there, I have never really done any Mac programming but I would like
> to chan
> > ge the "welcome to Macintosh. Connectix Ram Doubler" opening box at
startup to
> > a customized message..... can someone help me... or send advice, Thanks
> > jjacqu51@maine.maine.edu
>
> The "Welcome to Macintosh" message is stored in one of the STR or STR#
> resources in the System file (if I remember correctly) . Good luck
> finding it though. There are thousands. I've kept a list of
> miscellaneous strings I've run across in the past; but that one isn't in
> my list. Just in case, here they are:
[snip]
There is a nice little program, Errditor, which lets you edit the
startup messages. It won't let you change the Ram Doubler one though;
you might have to go messing with Ram Doubler resources or invisible
files to get at that one.
Errditor is on the usual Mac archives.
Simon
+++++++++++++++++++++++++++
>From microcsm@goldinc.com (David Blache)
Date: Sat, 02 Nov 1996 01:47:06 -0600
Organization: STAZ Software, Inc.
In article <96303.195858JJACQU51@MAINE.MAINE.EDU>,
<JJACQU51@MAINE.MAINE.EDU> wrote:
> HI there, I have never really done any Mac programming but I would like
to chan
> ge the "welcome to Macintosh. Connectix Ram Doubler" opening box at startup to
> a customized message..... can someone help me... or send advice, Thanks
> jjacqu51@maine.maine.edu
The "Welcome to Macintosh" message is stored in one of the STR or STR#
resources in the System file (if I remember correctly) . Good luck
finding it though. There are thousands. I've kept a list of
miscellaneous strings I've run across in the past; but that one isn't in
my list. Just in case, here they are:
"About This Macintosh..."
Finder: STR ID 10000 ...and...
Finder: STR# ID 5000, index# 56
"Finishing Move..."
Finder: STR# ID 8750, index# 16
"Clean Up Desktop" menu item
Finder: STR# ID 10250, index# 1
Font Example Text (when you open a font in the Finder):
Finder: STR# ID 14516, index# 1
"Starting Up..."
System 7.5 Update: STR -16502
+++++++++++++++++++++++++++
>From donarb@wolfenet.com (Don Arbow)
Date: Wed, 06 Nov 1996 09:59:19 -0800
Organization: Wolfe Internet Access, L.L.C.
In article <AjayToo-0311960027310001@cs1-01.lan.ptd.net>,
AjayToo@ptdprolog.net (AjayToo) wrote:
: In article <96303.195858JJACQU51@MAINE.MAINE.EDU>,
: <JJACQU51@MAINE.MAINE.EDU> wrote:
:
: > HI there, I have never really done any Mac programming but I would like
: to chan
: > ge the "welcome to Macintosh. Connectix Ram Doubler" opening box at
startup to
: > a customized message..... can someone help me... or send advice, Thanks
: > jjacqu51@maine.maine.edu
:
:
: You can replace that little phrase with one of your own, or with none at
: all. Begin by making a backup copy of the RAM Doubler extension, which you
: can do by option-dragging the original from the Extensions folder to the
: Startup Disk icon. Then use Apple's ResEdit utility to open the original
: RAM Doubler, and in the list of resource types that appears, double-click
: the DSAT type. Open the only DSAT resource, ID -4064, to see its contents.
: Then find the message on the right side of the resource-editing window,
: select it, and type a replacement (see "RAM Doubler Start-up"). Save your
: changes and restart the Mac to view your handiwork.
:
:
A better way is to install a custom picture screen. You can use this to
replace the Mac O/S two-faced pict. You can create a large PICT, you
should leave some space at the bottom for the loading status messages.
Then open up your System Update File with ResEdit or Resorcerer and paste
your PICT into resource -16506. There's a few similar resources there for
black and white and 8 bit screens. When you restart your machine, you'll
see your custom pict screen displayed.
Don
--
- ------------------------------------------------------------------------
\ | / Don Arbow, Partner, CTO | donarb@wolfenet.com
-- EDO -- EveryDay Objects, Inc. | http://www.pla-net.net/edo
/ | \ Seattle, WA |
- ------------------------------------------------------------------------
My Prographing web page: http://www.wolfe.net/~donarb/Dataflow.html
"The fix is only temporary, unless it works" - Red Green
- ------------------------------------------------------------------------
---------------------------
>From wouterfw@cistron.nl (Wouter)
Subject: Help: endian conversuin
Date: Mon, 04 Nov 1996 12:28:49 +0100
Organization: Human Software
Hi,
I am trying to import a file from PC with lots of numbers in it. Most of
them are 6 byte reals.
Are there any Converters around that I could use??
I'd like to convert the PC real to Mac double.
Maybe it would be nice to have a general purpose converter....
Thanx
Wouter
+++++++++++++++++++++++++++
>From Conal Walsh <conal@ind.tansu.com.au>
Date: Tue, 5 Nov 1996 15:53:03 +1100
Organization: Telstra
On Mon, 4 Nov 1996, Wouter wrote:
> Hi,
>
> I am trying to import a file from PC with lots of numbers in it. Most of
> them are 6 byte reals.
>
> Are there any Converters around that I could use??
>
> I'd like to convert the PC real to Mac double.
>
> Maybe it would be nice to have a general purpose converter....
>
I suspect you will have to do this conversion the hard way; i.e. extract
the mantissa, exponent and sign bit individually and use these to create a
"double" on the Mac. Use frexp() to apply the exponent to the mantissa.
Also, check the order of bytes in the mantissa; it is probably little
endian (least significant byte first).
/||\ Conal Walsh
/ ||/ Correct Procedures Pty Ltd Engineering and Consultancy
\ || Sydney, Australia Services for the
\|| correct@mypostbox.com Telecommunications Industry
"Some people live in the fast lane; I live in the oncoming traffic."
+++++++++++++++++++++++++++
>From sch@unx.sas.com (Steve Holzworth)
Date: Wed, 6 Nov 1996 18:32:35 GMT
Organization: SAS Institute Inc.
Conal Walsh <conal@ind.tansu.com.au> writes:
>On Mon, 4 Nov 1996, Wouter wrote:
>> Hi,
>>
>> I am trying to import a file from PC with lots of numbers in it. Most of
>> them are 6 byte reals.
>>
>> Are there any Converters around that I could use??
>>
>> I'd like to convert the PC real to Mac double.
>>
>> Maybe it would be nice to have a general purpose converter....
>>
>I suspect you will have to do this conversion the hard way; i.e. extract
>the mantissa, exponent and sign bit individually and use these to create a
>"double" on the Mac. Use frexp() to apply the exponent to the mantissa.
>Also, check the order of bytes in the mantissa; it is probably little
>endian (least significant byte first).
To help with this, you might want to search the web for sources to XDR
(eXternal Data Representation) libraries, which are used to read and write
assorted binary C data types, including floats. It even supports VMS native
float format (different from IEEE). The code as described won't act as a
convertor, but will give you good examples of how to deal with endian changes.
XDR routines assume that they wrote the data out, so they swap endians et al
based on what their target neutral format is. You might luck out and find
that the PC standard format is the same as that expected by XDR.
The code was originally written by Sun Microsystems, but is generally
available in source form now.
--
Steve Holzworth
sch@unx.sas.com "Do not attribute to poor spelling
SAS Institute x6872 That which is actually poor typing..."
Open Systems R&D VMS/MAC/UNIX - me
Cary, N.C.
---------------------------
>From "Brian Mowatt" <Brian.Mowatt@dial.pipex.com>
Subject: How common is 512 x 342 max res?
Date: 1 Nov 1996 10:32:25 GMT
Organization: Crocodile Clips Ltd.
Hi there,
Ive been developing an app that really depends on the max
screen resolution being a minimum of 640 x 4??. Lo and behold
when doing beta testing I encountered color classics, screen resolution
being a max of 512 x 342.
To rewrite the program to support the lower res would be a REAL pain,
so does anyone out there know how common this is the max res?
If its any I've noted that the only four macs I can find that support my
app
in all other respects bar resolution are:
Mac SE/30, MacClassic II, Color Classic, Color Classic II.
P.S. If anyone could point me in the direction of somewhere with mac sales
'by type' I'd be their friend for life! I've searched the Web but maybe I
missed it
Thanks in advance,
--
Brian.Mowatt@dial.pipex.com
Software developer
Crocodile Clips Lrd.
+++++++++++++++++++++++++++
>From Greg Jorgensen <gregj@europa.com>
Date: Wed, 06 Nov 1996 21:56:46 -0800
Organization: europa communications inc.
Brian Mowatt wrote:
>
> Hi there,
> Ive been developing an app that really depends on the max
> screen resolution being a minimum of 640 x 4??. Lo and behold
> when doing beta testing I encountered color classics, screen resolution
> being a max of 512 x 342.
>
> To rewrite the program to support the lower res would be a REAL pain,
> so does anyone out there know how common this is the max res?
> If its any I've noted that the only four macs I can find that support my
> app
> in all other respects bar resolution are:
> Mac SE/30, MacClassic II, Color Classic, Color Classic II.
> P.S. If anyone could point me in the direction of somewhere with mac sales
> 'by type' I'd be their friend for life! I've searched the Web but maybe I
> missed it
> Thanks in advance,
That isn't the only resolution you'll find smaller than 640 x 480. Apple
sold 12" color monitors for a while that are 600 x 400 or something like
that. When sales dried up they unloaded the monitors into schools. They
are the bane of all educational software developers, and only recently
have they been replaced in some schools with 13" monitors.
All of the PowerBooks prior to the 180c and the Duo 280 (I think that's
the model number) had LCD screens smaller than 640 x 480.
If you want your code to be compatible with all Mac you'll have to
support the lower resolutions.
The freeware utility database "Guru," available in the usual places, has
some good info. And Ziff-Davis used to publish a Mac models database but
I don't know how current it is. Apple dealers get little pocket booklets
and wall posters showing all of the Mac models and their specs. If you
can't get one from a dealer, call Apple at (408) 996-1010 and ask for
one. When you have a question about Apple's sales figures or their specs
it's always best to first call them; I've never seen them answer that
kind of question in a Usenet group.
--
Greg Jorgensen - Portland, Oregon, USA - gregj@europa.com
"Not only is there but one way of doing things rightly, but there is
only one way of seeing them, and that is seeing the whole of them." --
Ruskin
---------------------------
>From mieczko1@acsu.buffalo.edu (Mark C Mieczkowski)
Subject: ML for macintosh?
Date: 25 Oct 1996 01:43:40 GMT
Organization: UB
Hi,
Has anyone heard of an implementation of ML for the macintosh?
thanks,
-Mark
+++++++++++++++++++++++++++
>From seagull@seagull.net (Seagull Networks)
Date: Fri, 25 Oct 1996 22:54:35 -0700
Organization: Seagull Networks
In article <54p60c$3nl@prometheus.acsu.buffalo.edu>,
mieczko1@acsu.buffalo.edu (Mark C Mieczkowski) wrote:
> Hi,
> Has anyone heard of an implementation of ML for the macintosh?
>
> thanks,
> -Mark
There's Caml Light. You can find a copy of it at:
<ftp://ftp.inria.fr/lang/caml-light/>
______________________________________________________________________
Seagull Networks - offering quality web hosting at affordable prices
Visit <http://www.seagull.net/> for more information
+++++++++++++++++++++++++++
>From yeung@reed.edu (Woodrow Yeung)
Date: Fri, 25 Oct 1996 16:46:42 -0600
Organization: Reed College
In article <54p60c$3nl@prometheus.acsu.buffalo.edu>,
mieczko1@acsu.buffalo.edu (Mark C Mieczkowski) wrote:
> Hi,
> Has anyone heard of an implementation of ML for the macintosh?
Yes! You can find it at:
ftp://research.att.com/dist/ml/mac
Woody Yeung
yeung@reed.edu
+++++++++++++++++++++++++++
>From benjasik@cs.princeton.edu (Benji Jasik)
Date: Fri, 25 Oct 1996 23:20:21 -0800
Organization: Princeton Univesity
In article <54p60c$3nl@prometheus.acsu.buffalo.edu>,
mieczko1@acsu.buffalo.edu (Mark C Mieczkowski) wrote:
> Hi,
> Has anyone heard of an implementation of ML for the macintosh?
Check out:
http://www.cs.princeton.edu/~appel/smlnj/announce.93.html
+++++++++++++++++++++++++++
>From William Clodius <wclodius@lanl.gov>
Date: Tue, 05 Nov 1996 11:40:09 -0700
Organization: Los Alamos National Lab
Mark C Mieczkowski wrote:
>
> Hi,
> Has anyone heard of an implementation of ML for the macintosh?
>
> thanks,
> -Mark
There are several versions available (see the comp.lang.ml FAQ
http://www.cs.cmu.edu/afs/cs.cmu.edu/user/jgmorris/web/sml-faq.html)
SML/NJ (this is very memory intensive, but the most complete version)
http://cm.bell-labs.com/cm/cs/what/smlnj/announce.93.html
CAML/Light (byte code?)
http://pauillac.inria.fr:80/caml/distrib-caml-light-eng.html
Moscow ML (based on CAML/Light) (byte code)
ttp://www.dina.kvl.dk/~sestoft/mosml.html
Note SML is undergoing a change in its standard definition
http://cm.bell-labs.com/cm/cs/what/smlnj/sml96.html
If you are interested in ML on the Mac you might also be interested in
the related languages Clean
http://www.cs.kun.nl/~clean/
Haskell (Interpreter?)
http://haskell.systemsz.cs.yale.edu/haskell/yale/oldStuff/
Sisal (Interpreter)
http://www.llnl.gov/sisal/SisalHomePage.html
and Gofer (a dialect of Haskell (Interpreter)
ftp://ftp.dcs.glasgow.ac.uk/pub/haskell/gofer/macgofer/
--
William B. Clodius Phone: (505)-665-9370
Los Alamos National Laboratory Email: wclodius@lanl.gov
Los Alamos, NM 87545
---------------------------
>From Barry Wark <warkx001@maroon.tc.umn.edu>
Subject: Q: how do I crop and then resave a PICT file?
Date: Fri, 01 Nov 1996 18:03:41 -0600
Organization: University of Minnesota
I would like to be able to open a PICT file in my C++ program (I'm using
TCL 2.0), allow the user to select a portion of the picture, then resave
just the selected portion of the picture. Can I do this without
resorting to parsing the PICT file code?
TIA
--
Sincerely,
Barry J. Wark
"Imagination is more important than knowledge." -- Albert Einstein
- ---BEGIN PGP PUBLIC KEY BLOCK-----
Version: 2.6.2
mQBvAzFpg1EAAAEDAMgoFiLYOLS6z6qLydIpe0FK+0HQFrQjKS/3Me66qaWGkhvK
OImflWOoDnVO7sxlivyAjmj0uzfw5yT3N/lHPOOxADtl9O3rFscj2DiaSuYYNP4W
LJBszHVxslNG9PdwsQARAQABtCpCYXJyeSBKLiBXYXJrIDx3YXJreDAwMUBtYXJv
b24udGMudW1uLmVkdT4=
=ieUK
- ---END PGP PUBLIC KEY BLOCK-----
+++++++++++++++++++++++++++
>From Joshua C Horan <horan+@andrew.cmu.edu>
Date: Fri, 1 Nov 1996 22:47:05 -0500
Organization: Freshman, MCS Undeclared, Carnegie Mellon, Pittsburgh, PA
Excerpts from netnews.comp.sys.mac.programmer.help: 1-Nov-96 Q: how do I
crop and then r.. by Barry Wark@maroon.tc.umn
> I would like to be able to open a PICT file in my C++ program (I'm using
> TCL 2.0), allow the user to select a portion of the picture, then resave
> just the selected portion of the picture. Can I do this without
> resorting to parsing the PICT file code?
>
Couldn't you just copy the picture to an offscreen, get the user's rect
and then do another copybits using that rect inside a
OpenPicture()/ClosePicture() wrapper?
I think you need to look into the OpenPicture() and ClosePicture()
toolbox calls. Check out IM Imaging W/ Quickdraw.
Josh Horan
+++++++++++++++++++++++++++
>From carl.gustafson@no.spam.welcome (Carl Gustafson)
Date: Mon, 04 Nov 1996 10:06:25 -0500
Organization: Imaging and Computer Vision Center, Drexel University
In article <327A8FDD.6F39@maroon.tc.umn.edu>, Barry Wark
<warkx001@maroon.tc.umn.edu> wrote:
> I would like to be able to open a PICT file in my C++ program (I'm using
> TCL 2.0), allow the user to select a portion of the picture, then resave
> just the selected portion of the picture. Can I do this without
> resorting to parsing the PICT file code?
After getting the rectangle your user wants the picture cropped to, do an
OpenPicture (), followed by CopyBitsing that rectangle onto the same pixel
map. End by doing a ClosePicture (), and saving the resulting picture to a
file.
--
Carl Gustafson
carl.gustafson at ece.drexel.edu
(busily trying to avoid spammers)
Imaging and Computer Vision Center
Drexel University, Philadelphia, Penna
- ----------------------------------------------------------
I don't speak for Drexel, and Drexel doesn't listen to me...
+++++++++++++++++++++++++++
>From mouser@zercom.net (Martin-Gilles Lavoie)
Date: 5 Nov 1996 13:49:29 GMT
Organization: Groupimage, inc.
In article <327A8FDD.6F39@maroon.tc.umn.edu>, Barry Wark
<warkx001@maroon.tc.umn.edu> wrote:
> I would like to be able to open a PICT file in my C++ program (I'm using
> TCL 2.0), allow the user to select a portion of the picture, then resave
> just the selected portion of the picture. Can I do this without
> resorting to parsing the PICT file code?
>
Yup. Basically, there are two ways of doing this, depending if you want
to remain vector information, or just keep a bitmap of the selected area.
Here's the pseudocode for it (I'm in a lazy mood this morning):
draw original image in window
cropped image = open new color picture
if bitmap version
copybits cropped area in place
or vectorial version
draw original image
end
close picture
[premission granted to hate this pseudo-code syntax]
--
Martin-Gilles Lavoie | Opinions expressed herein are just that.
mouser@zercom.net | "No! Do, or do not. There is no try."
Globimage, inc. | --Yoda on error handling
---------------------------
>From "Zane H. Healy" <healyzh@ix.netcom.com>
Subject: ResEdit 'TMPL' question
Date: Sun, 03 Nov 1996 23:29:00 -0800
Organization: Netcom
I'm tring to create a ResEdit template for custom resource. I've looked
at the documentation on ResEdit, and I've a couple of questions.
Is 'DWRD' the equivalent of a 'int' in C, and is 'DLNG' the equivalent
of a 'long' in C? If not what is?
It's a case of I'd like to know the right way to do it prior to writing
the code, and typing all the data into ResEdit. Is that as lazy as it
sounds?
Thank you for your time.
Zane
+++++++++++++++++++++++++++
>From Greg Jorgensen <gregj@europa.com>
Date: Wed, 06 Nov 1996 21:59:52 -0800
Organization: europa communications inc.
Zane H. Healy wrote:
>
> I'm tring to create a ResEdit template for custom resource. I've looked
> at the documentation on ResEdit, and I've a couple of questions.
>
> Is 'DWRD' the equivalent of a 'int' in C, and is 'DLNG' the equivalent
> of a 'long' in C? If not what is?
Close. DWRD is the equivalent of a C short integer. It will also be the
same as a C int if the compiler is set to use 2-byte ints, but the size
of an int is not defined to be any particular size. DLNG is equivalent
to a C long integer.
> It's a case of I'd like to know the right way to do it prior to writing
> the code, and typing all the data into ResEdit. Is that as lazy as it
> sounds?
Use Resorcerer. It can change the data for you after you've entered it
if you have to change the template. And it has much better documentation
that ResEdit.
--
Greg Jorgensen - Portland, Oregon, USA - gregj@europa.com
"Not only is there but one way of doing things rightly, but there is
only one way of seeing them, and that is seeing the whole of them." --
Ruskin
---------------------------
>From Gerald Winslow <winslow@hous.inmet.com>
Subject: Symantec C++ going away?
Date: Tue, 5 Nov 1996 01:32:02 GMT
Organization: Intermetrics, Inc.
I heard that Symantec is decreasing their Mac C++ effort in order to
increase their Mac Java effort. I didn't know if this was true, but
then I saw the latest Apple Dev Catalog, in which the Sym. C++ package
was priced very low (< $150). That lead me to believe the rumor. So,
is it true? Will MetroWerks have only Apple as their competitor?
Thanks for any info!
Gerald Winslow
Senior Engineer
Intermetrics, Inc.
winslow@hous.inmet.com
+++++++++++++++++++++++++++
>From pteeson@interlog.com (Peter Teeson)
Date: Tue, 05 Nov 1996 08:47:52 -0600
Organization: InterLog Internet Services
In article <327E9912.680F@hous.inmet.com>, winslow@hous.inmet.com wrote:
>I heard that Symantec is decreasing their Mac C++ effort in order to
>increase their Mac Java effort. I didn't know if this was true, but
>then I saw the latest Apple Dev Catalog, in which the Sym. C++ package
>was priced very low (< $150). That lead me to believe the rumor. So,
>is it true? Will MetroWerks have only Apple as their competitor?
>
>Thanks for any info!
>
>Gerald Winslow
>Senior Engineer
>Intermetrics, Inc.
>winslow@hous.inmet.com
Symantec closed their Bedford Massachusets office a few months ago.
They renamed their development tools group to Internet Tools group
or something like that. Some people moved to CA and last I heard they
were trying to hire for the group.
They have publicly stated they will continue with their C++ effort.
I have absolutley no confidence that they will do so nor do I have evidence
that they will. OTOH I do have evidence that they don't follow through.
For example I found and reported a probable bug in the C++ pre-processor
wrt nested macro expansions. I was assured that "....you will be kept in the loop....".
Hah.
Although their IDE has some pretty important and nice features that are not yet
in CodeWarrior, (multiple open projects, nested projects, a more mature compiler),
etc I expect CW will get there one day.
I also note the fall in the Symantec share price. Even their shareholders must be getting
nervous at the price drop.
Putting it all together I conclude they don't really care anymore.... not the engineers
of course but the giant brains running the oompany.
Just my personal opinion though.
Peter
--
General Consulting & Research Inc.
712 - 24 Forest Manor Road
Willowdale, ON
M2J 1M3
416-494-5888 voice 416-494-4832 fax
"Developing quality software requires a great deal of effort
over a long period of time." Doug Schmidt - C++ Report May 1996
+++++++++++++++++++++++++++
>From tree@apple.com (Tom Emerson)
Date: Tue, 05 Nov 1996 10:51:14 -0500
Organization: Apple Computer, Inc.
In article <pteeson-0511960847530001@ip203-117.cc.interlog.com>,
pteeson@interlog.com (Peter Teeson) wrote:
>They have publicly stated they will continue with their C++ effort.
>I have absolutley no confidence that they will do so nor do I have evidence
>that they will. OTOH I do have evidence that they don't follow through.
I agree with Peter that Symantec has a definite history of not following
through, in all of their products on Wintel and Mac.
The important thing to remember, though, is that the Macintosh Java effort
is based on technology that came from the Bedford office, and the Java
teams are using the Symantec tools for their work. By necessity the core
tools will be maintained and enhanced, as required.
>For example I found and reported a probable bug in the C++ pre-processor
>wrt nested macro expansions. I was assured that "....you will be kept in
the loop....".
>Hah.
Well, you probably have. The problem is that there probably hasn't been any
news to inform you of. I reported a bug const bug in the compiler and was
told that I'd be kept in the loop too...
>I also note the fall in the Symantec share price. Even their shareholders
>must be getting nervous at the price drop.
If you think there is any relation between the stock price and Symantec C++
you are *very* mistaken. Symantec's stock went in the toilet months before
anything happened to Bedford, and it certainly was *not* related to C++.
Indeed, until Java the development tools portions of the company were a
flea on a large rat.
>Putting it all together I conclude they don't really care anymore.... not
>the engineers of course but the giant brains running the oompany.
I would posit that management, with a couple of exceptions, didn't care
*ever*. One of the reasons I left.
>Just my personal opinion though.
Ditto.
-tre
--
Tom Emerson Cambridge R&D
Senior Software Engineer Apple Computer, Inc.
<mailto:tree@apple.com> <http://www.tiac.net/users/tree>
+++++++++++++++++++++++++++
>From tree@apple.com (Tom Emerson)
Date: Tue, 05 Nov 1996 10:22:45 -0500
Organization: Apple Computer, Inc.
In article <327E9912.680F@hous.inmet.com>, winslow@hous.inmet.com wrote:
>I heard that Symantec is decreasing their Mac C++ effort in order to
>increase their Mac Java effort. I didn't know if this was true, but
>then I saw the latest Apple Dev Catalog, in which the Sym. C++ package
>was priced very low (< $150). That lead me to believe the rumor. So,
>is it true? Will MetroWerks have only Apple as their competitor?
Symantec decided to reduce the price of Symantec C++ six or seven months
ago in an effort to make it more (financially) appealing for developers to
"give it a try".
It is true that Symantec is focusing on Java on both the Intel and
Macintosh platforms, though they are keeping a "core tools" group which is
focusing on the C/C++ compilers and environment. Work is continuing on the
IDE and releases are scheduled for the end of the year (last I heard).
-tre
--
Tom Emerson Cambridge R&D
Senior Software Engineer Apple Computer, Inc.
<mailto:tree@apple.com> <http://www.tiac.net/users/tree>
+++++++++++++++++++++++++++
>From nagle@netcom.com (John Nagle)
Date: Tue, 5 Nov 1996 17:43:29 GMT
Organization: NETCOM On-line Communication Services (408 261-4700 guest)
tree@apple.com (Tom Emerson) writes:
>In article <pteeson-0511960847530001@ip203-117.cc.interlog.com>,
>pteeson@interlog.com (Peter Teeson) wrote:
>>They have publicly stated they will continue with their C++ effort.
>>I have absolutley no confidence that they will do so nor do I have evidence
>>that they will. OTOH I do have evidence that they don't follow through.
>I agree with Peter that Symantec has a definite history of not following
>through, in all of their products on Wintel and Mac.
As I've mentioned before, Symantec seems to have a sort of
product cycle, like the auto industry.
They get a product working, promote it heavily, get sales up, and then
don't change it much for a few years. Once sales slip seriously and the trade
magazines start saying bad things, they put some resources into the
product and do a major revision. The Norton Utilities and the C/C++
tools have both been through this cycle about three times each.
John Nagle
---------------------------
>From pburgst@cs.bgsu.edu (Peter Burgstaller)
Subject: Texteditor needed w- AppleScript
Date: Tue, 05 Nov 1996 20:24:19 -0500
Organization: Bowling Green State University
Hi folks,
I need a text editor that can handle files bigger than 32k and is
scriptable via AppleScript. Ideally it should implement most of the
features of the Scriptable Text Editor from apple.
- Anybody knows such an editor?
- Pls let me know via email, THANX!!!!!
- Peter
(pburgst@cs.bgsu.edu)
+++++++++++++++++++++++++++
>From uzs90z@uni-bonn.de (Michael Schuerig)
Date: Wed, 6 Nov 1996 15:48:31 +0100
Organization: RHRZ - University of Bonn (Germany)
Peter Burgstaller <pburgst@cs.bgsu.edu> wrote:
> I need a text editor that can handle files bigger than 32k and is
> scriptable via AppleScript. Ideally it should implement most of the
> features of the Scriptable Text Editor from apple.
Look for Style on info-mac.
Michael
- -
Michael Schuerig
mailto:uzs90z@uni-bonn.de
http://www.rhrz.uni-bonn.de/~uzs90z/
+++++++++++++++++++++++++++
>From dan@rhino.harvard.edu (Dan Crevier)
Date: Wed, 06 Nov 1996 09:24:54 -0500
Organization: Harvard University
In article <pburgst-0511962024190001@ts55.wcnet.org>, pburgst@cs.bgsu.edu
(Peter Burgstaller) wrote:
>I need a text editor that can handle files bigger than 32k and is
>scriptable via AppleScript. Ideally it should implement most of the
>features of the Scriptable Text Editor from apple.
I think Marco Piovanelli's Style is exactly what you are looking for.
Check out <ftp://rhino.harvard.edu//pub/dan/WASTE/style-143.hqx>
Dan
--
Dan Crevier <Dan.Crevier@pobox.com>
<http://rhino.harvard.edu/dan/home.html>
+++++++++++++++++++++++++++
>From Tom Carstensen <tom@countach.visix.com>
Date: 06 Nov 1996 11:24:20 -0500
Organization: Visix Software Inc.
In article <pburgst-0511962024190001@ts55.wcnet.org> pburgst@cs.bgsu.edu (Peter Burgstaller) writes:
>I need a text editor that can handle files bigger than 32k and is
>scriptable via AppleScript. Ideally it should implement most of the
>features of the Scriptable Text Editor from apple.
Preditor is a fully scriptable and recordable text editor. For more
info refer to http://www.evatac.com.
--
Tom Carstensen tom@evatac.com
President http://www.evatac.com
Evatac Software 703.620.0669 (alt: 703.758.2835)
Galaxy & Macintosh Software
Development & Consulting
+++++++++++++++++++++++++++
>From bbsw@netcom.com (Bare Bones Software)
Date: Wed, 6 Nov 1996 15:37:12 GMT
Organization: Bare Bones Software, Inc.
In article <pburgst-0511962024190001@ts55.wcnet.org> pburgst@cs.bgsu.edu (Peter Burgstaller) writes:
>I need a text editor that can handle files bigger than 32k and is
>scriptable via AppleScript. Ideally it should implement most of the
>features of the Scriptable Text Editor from apple.
BBEdit 4.0 may serve your needs; have a look at <http://www.barebones.com/>
for more information.
Regards,
Rich Siegel
Bare Bones Software, Inc.
---------------------------
>From masunta@news.siba.fi (Miika Asunta)
Subject: Writing ioCompletion routine for Device Manager
Date: 4 Nov 1996 00:03:24 +0200
Organization: Sibelius Academy, Helsinki
I need a C function prototype for a typical ioCompletion routine for
asynchronous Device Manager call.
And where I store the A5 value to acces my globals?
This is easy with Notification and Sound Manager as well
as CTB - well documented.
I've read Inside Macintosh II, IV and VI pages containing information on
the routine but I only see a description useful for Assembly languace
call.
Thanks in advance!
--
Miika Asunta Double Bass Player
Miika.Asunta@siba.fi Macintosh Programmer
tel. +358-0-7374 89
GSM: +358-40-5477 842 http://www.siba.fi/~masunta
+++++++++++++++++++++++++++
>From cho@kenner.demon.co.uk (Chris Orgill)
Date: Wed, 06 Nov 1996 01:20:46 +0100
Organization: (none)
In article <masunta.847058213@amadeus.siba.fi>, masunta@news.siba.fi (Miika
Asunta) wrote:
> I need a C function prototype for a typical ioCompletion routine for
> asynchronous Device Manager call.
>
> And where I store the A5 value to acces my globals?
> This is easy with Notification and Sound Manager as well
> as CTB - well documented.
>
> I've read Inside Macintosh II, IV and VI pages containing information on
> the routine but I only see a description useful for Assembly languace
> call.
>
> Thanks in advance!
>
> --
> Miika Asunta Double Bass Player
> Miika.Asunta@siba.fi Macintosh Programmer
> tel. +358-0-7374 89
> GSM: +358-40-5477 842 http://www.siba.fi/~masunta
Look at Develop Issue #13. Jim Luther wrote a definitive article
explaining asynch. completion routines for 68k. You need some
assembler glue :-( It's a mess. The article does _not mention PPC completion
procedures, however. They should be easier.
Chris Orgill
+++++++++++++++++++++++++++
>From doverton@iglou.com (Dave Overton)
Date: Tue, 5 Nov 1996 04:21:37 GMT
Organization: IgLou Internet Services (1-800-436-4456)
One good place to store your A5 is to place it in a structure after your
parameter block for your call in your calling routine. Then in your
completion routine, cast the pointer to the parameter block as one of your
structures. ( Which it must be, or it wouldn't be passed to your
completion routine. ) The odd thing about completion routines in C is that
you must retrieve the value in Register A0 and place it in a variable to
access your parameter block.This can be done by placing code to get A0 in
line with 68K machine code. If you need an example of this, e-mail me at
doverton@iglou.com and I will dig something up. ( Hopefully, not someone's
mother ) ( Ha Ha )
Dave Overton
In article <masunta.847058213@amadeus.siba.fi>, masunta@news.siba.fi
(Miika Asunta) wrote:
> I need a C function prototype for a typical ioCompletion routine for
> asynchronous Device Manager call.
>
> And where I store the A5 value to acces my globals?
> This is easy with Notification and Sound Manager as well
> as CTB - well documented.
>
> I've read Inside Macintosh II, IV and VI pages containing information on
> the routine but I only see a description useful for Assembly languace
> call.
>
> Thanks in advance!
>
> --
> Miika Asunta Double Bass Player
> Miika.Asunta@siba.fi Macintosh Programmer
> tel. +358-0-7374 89
> GSM: +358-40-5477 842 http://www.siba.fi/~masunta
---------------------------
>From Bill Rose <rosewj@tr.unisys.com>
Subject: [Q] Cross platform Development (Mac-Windows)...
Date: Tue, 5 Nov 1996 19:06:20 GMT
Organization: Unisys Corp.
Hi:
Besides the offerings from Pictorius, are there any other cross platform
programming environments for the Mac? I want to be able to produce
projects that will compile and run on both a Mac (PPC) and Windows
(3.1/95)?
Thanks
--
Bill Rose
rosewj@tr.unisys.com
Unisys Corporation
- ------------------------------------------------------------
'What a waste it is to lose one's mind - or not to have a mind. How
true that is.'
Vice-President Dan Quayle addressing a United Negro College Fund
affair and garbling their slogan - 'A mind is a terrible thing
to waste.'
+++++++++++++++++++++++++++
>From jpek@bizserve.com (Jeff Pek)
Date: Wed, 06 Nov 1996 16:40:24 -0500
Organization: Various Organizations
In article <327F902C.312E@tr.unisys.com>, rosewj@tr.unisys.com wrote:
> Besides the offerings from Pictorius, are there any other cross platform
> programming environments for the Mac? I want to be able to produce
> projects that will compile and run on both a Mac (PPC) and Windows
> (3.1/95)?
There's a few different approaches (and probably an FAQ somewhere...):
1) Cross-platform API (e.g., Zinc/zApp/...)
You write to a proprietary UI api, which is then implemented on
multiple platforms. This may be a good way to go if you don't already
have code written on a system-specific API. You may lose platform
look&feel somewhat, and it will likely be slower than native.
2) Implement Mac & port to Windows.
I know of at least one company that provides port of Mac toolbox
on top of Windows API: Altura. They have a product called Mac2Win
that works this way. This would be a good way to go if you already
have a Mac product that you want to migrate to Windows without a
complete rewrite.
3) (Converse) Implement Windows & port to Mac.
Microsoft and Willows sell porting packages that implement the
Windows API on Mac. If you already have Windows app (or expertise),
this may be a good solution.
hth - Jeff
--
Jeff Pek
Development Manager
Gene Codes Corp - Ann Arbor, MI
jpek@genecodes.com
+++++++++++++++++++++++++++
>From got@pobox.com (Gordon Tillman)
Date: Wed, 06 Nov 1996 17:04:11 -0500
Organization: n/a
Hey Bill,
You had written:
> Besides the offerings from Pictorius, are there any other cross platform
> programming environments for the Mac? I want to be able to produce
> projects that will compile and run on both a Mac (PPC) and Windows
> (3.1/95)?
Interesting question. I've been looking at a variety of alternatives
myself. I won't repeat what Jeff has already said, but I would like to
add a few other possibilities to the mix:
(1) Java
(2) Python
(3) TCL/Tk
(4) Perl 5
I am no expert on any of these languages/environments, so I cannot comment
yet as to how good or complete the various offerings are. I just wanted
to make you aware of some other options.
--gordon tillman (got@pobox.com)
---------------------------
>From mwehner@lince.lander.es (Mephisto)
Subject: [Q] Is there a function like GetDirContent()?
Date: Sun, 03 Nov 1996 20:00:29 +0200
Organization: Lander Internet
Dear Mac Programmers,
I know this is a pretty stupid question but anyway... maybe there's
someone who can help me....
I want to create a shell-application similar to a UNIX input
My application should support the ls command...... (and cd and all that stuff)
The shell is not the problem, but:
how do I get a list with the contents of a folder?
There HAS to be a function that gives me a list of all items in a folder -
maybe even one that tells me if that item is a file or a folder!
I tried to find some unix command - but there doesn't seem to be one in my
library
I feel pretty stupid to be honest - can you help me?
If you got some spare-time, could you please also send me some example
source-code? Just with this function!?!
(c++ would be best!)
Thank you very much!!
Please send any answers, demos, flames or whatever to: mwehner@lander.es
Yours,
Martin
+++++++++++++++++++++++++++
>From gwilson685@aol.com
Date: 5 Nov 1996 20:58:40 GMT
Organization: America Online, Inc. (1-800-827-6364) (1.10)
Here's a routine I wrote to build a table of all the files within a given
directory.
It differentiates between files and folders as well.
Code seems stable, but I haven't tested it thoroughly,it's good enough to
give you the idea.
Basically, you loop doing PBGetCatInfoSync giving it a incremented index
Hope this helps
Greg
//
- ------------------------------------------------------------------------
-
// BuildFromDirectory(long dirID)
//
- ------------------------------------------------------------------------
-
// determine which files reside in a directory and add them to the
table
short LFileTable::BuildFromDirectory(long dirID)
{
Str255 DirectoryName;
Str255 fileName;
long currentDirID;
short vRefNum;
short file_idx = 1;
CInfoPBPtr catPBBlockPtr =
(CInfoPBPtr)NewPtrClear(sizeof(CInfoPBRec));
// first, find out our default directory, really just doing this
to get our vref
OSErr theErr = HGetVol(nil, &vRefNum, ¤tDirID);
catPBBlockPtr->hFileInfo.ioCompletion = nil;
catPBBlockPtr->dirInfo.ioCompletion = nil;
catPBBlockPtr->hFileInfo.ioNamePtr = (unsigned char *)&fileName;
while (!theErr) {
catPBBlockPtr->dirInfo.ioDrDirID = dirID;
catPBBlockPtr->dirInfo.ioVRefNum = vRefNum;
catPBBlockPtr->hFileInfo.ioFDirIndex = file_idx;
theErr = PBGetCatInfoSync(catPBBlockPtr);
if ( !theErr) {
UInt32 theIconID = 1000; // assume it's a
document
// according to IM -IV-155 you can tell it's a
directory by testing bit four
// of the ioFlAttrib (as described in the
CInfoPBRec)
SInt8 theBit;
theBit = catPBBlockPtr->hFileInfo.ioFlAttrib &
0x10;
if (theBit)
theIconID = 1001;
l face a major memory leak!!!
theTableItem = new STableItem(theIconID, fileName,
catPBBlockPtr->hFileInfo.ioDirID);
this->InsertRows(1, file_idx-1, theTableItem,
sizeof(STableItem), false);
++file_idx;
}
}
// thanks for the memory!
DisposePtr((Ptr)catPBBlockPtr);
if ( currentDirID != dirID)
// set up this new directory as the working directory
HSetVol(nil, vRefNum, dirID);
if ( file_idx > 1 ) {
STableCell theCell, theLastCell;
TableIndexT numRows, numCols;
theCell.col = 1;
theCell.row = 1;
// we want to redraw the whole table before we do any
selection
// cuz selecting will force the decoding of the jpeg image
FocusDraw();
GetTableSize(numRows, numCols);
theLastCell.col = numCols;
theLastCell.row = numRows;
RefreshCellRange(theCell, theLastCell);
// to get the thing to refresh, we have to force the
window to redraw
// as if the update event was being processed now
this->ScrollImageTo(0, 0, false);
this->UpdatePort();
this->SelectCell(theCell);
}
return (file_idx);
}
Wilson's Second Law
e raised to the infinity is greater than 4
+++++++++++++++++++++++++++
>From phenix@interpath.com (John Moreno)
Date: Tue, 5 Nov 1996 21:32:42 -0500
Organization: phenix@interpath.com
Mephisto <mwehner@lince.lander.es> wrote:
] Dear Mac Programmers,
]
] I know this is a pretty stupid question but anyway... maybe there's
] someone who can help me....
]
] I want to create a shell-application similar to a UNIX input My
] application should support the ls command...... (and cd and all that
] stuff) The shell is not the problem, but: how do I get a list with the
] contents of a folder? There HAS to be a function that gives me a list
] of all items in a folder - maybe even one that tells me if that item
] is a file or a folder! I tried to find some unix command - but there
] doesn't seem to be one in my library I feel pretty stupid to be honest
] - can you help me?
]
] If you got some spare-time, could you please also send me some example
] source-code? Just with this function!?!
] (c++ would be best!)
]
] Thank you very much!!
]
] Please send any answers, demos, flames or whatever to:
] mwehner@lander.es
Look for MoreFiles 1.4 it can be used to do what you want, although
that's not a built in function.
--
John Moreno
+++++++++++++++++++++++++++
>From jumplong@aol.com
Date: 6 Nov 1996 04:01:48 GMT
Organization: America Online, Inc. (1-800-827-6364) (1.10)
Martin (mwehner@lince.lander.es) wrote:
>I want to create a shell-application similar to a UNIX input My
>application should support the ls command...... (and cd and all
>that stuff) The shell is not the problem, but:
> how do I get a list with the contents of a folder? There HAS
>to be a function that gives me a list of all items in a folder -
>maybe even one that tells me if that item is a file or a folder!
>I tried to find some unix command - but there doesn't seem to be
>one in my library I feel pretty stupid to be honest - can you
>help me?
Get a copy of MoreFiles from
<ftp://members.aol.com/JumpLong/MoreFiles_1.4.3.sea.hqx> and use the
GetDirItems function.
- Jim Luther
+++++++++++++++++++++++++++
>From Conal Walsh <conal@ind.tansu.com.au>
Date: Wed, 6 Nov 1996 14:08:44 +1100
Organization: Telstra
On Sun, 3 Nov 1996, Mephisto wrote:
> Dear Mac Programmers,
>
> I know this is a pretty stupid question but anyway... maybe there's
> someone who can help me....
>
> I want to create a shell-application similar to a UNIX input
Some time ago I wrote an app for 68k Macs to emulate an Applix 1616
environment. Ok, since most of the world has never heard of the "Applix
1616", it was a 68000 based machine with a pre-emptive multitasking
environment rather like unix. I developed my Mac version to the point
where it understands most of the basic commands (ls, cd, etc) and can run
executables. GNU C runs under it, so you can port missing commands to it
if desired. The app ceased to work when I changed to a PPC, partly because
the PPC thread manager doesn't support pre-emptive threads, and partly
because the 68k emulator that comes with PPCs doesn't appear to emulate
TRAP instructions. Lemme know if you want the source.
/||\ Conal Walsh
/ ||/ Correct Procedures Pty Ltd Engineering and Consultancy
\ || Sydney, Australia Services for the
\|| correct@mypostbox.com Telecommunications Industry
"Some people live in the fast lane; I live in the oncoming traffic."
---------------------------
>From jsoltys@woodinville.com (John Soltys)
Subject: [Q] why can't I write a short?
Date: Sun, 03 Nov 1996 12:26:41 -0800
Organization: The Edwards Agency
I'm trying to output a short to a text file using the following line:
myError = FSWrite (fileRef, &count, &curNode->selected[i]);
where fileRef is the reference of the already opened file, count = 1L, and
curNode->selected[i] is a pointer to an array of shorts in a struct.
I know the value of selected[i] is valid, but when I open the output file
I always wind up with a null character. Any ideas what's wrong?
+++++++++++++++++++++++++++
>From Greg Jorgensen <gregj@europa.com>
Date: Wed, 06 Nov 1996 21:48:17 -0800
Organization: europa communications inc.
Bob Bradley wrote:
[snip]
> A short is 2 bytes and FSWrite's count parameter is the count in bytes so
> you're telling it to write 1 byte. Try setting count to 2 instead of 1.
Better advice is to use sizeof(short) rather than hard-coding 2. A short
is two bytes on the Mac, but not everywhere. The size of a short integer
on every machine is sizeof(short).
--
Greg Jorgensen - Portland, Oregon, USA - gregj@europa.com
"Not only is there but one way of doing things rightly, but there is
only one way of seeing them, and that is seeing the whole of them." --
Ruskin
---------------------------
>From raterwil@ucla.edu (Robert Terwilliger)
Subject: displaying a pixmap on screen
Date: 1 Nov 1996 21:04:36 GMT
Organization: UCLA Division of Brain Mapping
I am trying to display a pixmap on a mac screen. I can't get it to look
the way I want it to. It is a 128x128 pixel 8-bit grayscale MRI image
which appears fine when I display it on NIH image but I cannot get it to
display on my program. Does anyone have experience reading in raw data
files (not picts, tiffs or other preformatted files) and displaying them
on the screen?
I do not know if I need to convert the image to 48-bit RGB before
displaying or what. If anyone can help me, please let me know. I can
forward you my code and explain exactly where the problem is.
I am using Code Warrior 9 and program in C.
Thank you.
Robert Terwilliger
+++++++++++++++++++++++++++
>From sauerzapf@mathematik.uni-kl.de (Oliver Sauerzapf)
Date: Sun, 03 Nov 1996 23:13:05 +0200
Organization: Brainworm Productions
In article <raterwil-0111961306040001@pawnx.loni.ucla.edu>,
raterwil@ucla.edu (Robert Terwilliger) wrote:
> I am trying to display a pixmap on a mac screen. I can't get it to look
> the way I want it to. It is a 128x128 pixel 8-bit grayscale MRI image
> which appears fine when I display it on NIH image but I cannot get it to
> display on my program. Does anyone have experience reading in raw data
> files (not picts, tiffs or other preformatted files) and displaying them
> on the screen?
>
> I do not know if I need to convert the image to 48-bit RGB before
> displaying or what. If anyone can help me, please let me know. I can
> forward you my code and explain exactly where the problem is.
>
> I am using Code Warrior 9 and program in C.
>
> Thank you.
>
> Robert Terwilliger
Hi Robert,
8-Bit color depth means, that a color lookup table is used.
You can display 256 different colors or grayscales at one time.
Every color( of the 256) has an index in the color lookup table
and a corresponding RGB value. Your picture is not using the
system color table. I gess that it has it's own.
This should be defined in the resouce "pltt" or"clut".
So you have to set the current color table with "SetPalette".
Bye Oliver
--
Don't forget !
Intel inside is a warning.
+++++++++++++++++++++++++++
>From jimmerkel@aol.com (Jim Merkel)
Date: 3 Nov 1996 16:16:38 -0500
Organization: America Online, Inc. (1-800-827-6364)
raterwil@ucla.edu (Robert Terwilliger) wrote:
>I am trying to display a pixmap on a mac screen. I can't get it to look
>the way I want it to. It is a 128x128 pixel 8-bit grayscale MRI image
>which appears fine when I display it on NIH image but I cannot get it to
>display on my program. Does anyone have experience reading in raw data
>files (not picts, tiffs or other preformatted files) and displaying them
>on the screen?
>
>I do not know if I need to convert the image to 48-bit RGB before
>displaying or what. If anyone can help me, please let me know. I can
>forward you my code and explain exactly where the problem is.
>
>I am using Code Warrior 9 and program in C.
>
>Thank you.
>
>Robert Terwilliger
One approach is to create a GWorld with a depth of 8-bits. Attach a 256
entry grayscale color table to the GWorld. Load the GWorld Pixmap with
your grayscale image data (8 bits per pixel), then do a copybits to your
window.
If you don't attach a color table to the GWorld, the system uses a default
color table which will probably not give you the results you want. The
grayscale color table that you want probably runs from black (0,0,0) in
the 0th location and then linearly increases to white (65535, 65535,
65535) in the 255th location. The system grayscale color table (resource
ID = 40) runs in the opposite direction. If you use it, you will probably
get a negative of the image. In other words. you may have to make your own
grayscale color table. You can do that in ResEdit (it's a pain but can be
done).
Jim Merkel
+++++++++++++++++++++++++++
>From squires@crl.com (Scott Squires)
Date: Sun, 03 Nov 1996 14:32:33 -0800
Organization: Puffin Designs
In article <raterwil-0111961306040001@pawnx.loni.ucla.edu>,
raterwil@ucla.edu (Robert Terwilliger) wrote:
>I am trying to display a pixmap on a mac screen. I can't get it to look
>the way I want it to. It is a 128x128 pixel 8-bit grayscale MRI image
>which appears fine when I display it on NIH image but I cannot get it to
>display on my program. Does anyone have experience reading in raw data
>files (not picts, tiffs or other preformatted files) and displaying them
>on the screen?
>
>I do not know if I need to convert the image to 48-bit RGB before
>displaying or what. If anyone can help me, please let me know. I can
>forward you my code and explain exactly where the problem is.
>
// untested psuedo code follows
// create a grayscale GWorld
CTabHandle theCTab;
QDErr iErr;
GWorldPtr theGWorld;
Rect theRect;
SetRect(&theRect,0,0,128,128);
theCTab = GetCTable(40); // standard 8 bit gray
iErr = NewGWorld(theGWorld,8,theRect,theCTab,0,0);
DisposeCTable(theCTab);
PixMapHandle srcPixMap = GetGWorldPixMap ( theGWorld );
long srcRowBytes = (**srcPixMap).rowBytes & 0x3fff; /* get the row
increment */
srcBaseAddr = (long) GetPixBaseAddr ( srcPixMap ); /* get the address of
the pixmap */
for(y=0;y<128;y++)
{
BlockMoveData(yourBuffer,srcBaseAddr,128);
srcBaseAddr += theRowBytes;
}
// now do a CopyBits to your window
CopyBits((BitMap *) * (srcPixMap), &GrafPtr(yourWindowPort)->portBits,
&theRect
, &theRect, srcCopy, 0);
-scott
Scott Squires "Insert funny stuff here"
squires@crl.com
ScottSquir@aol.com
+++++++++++++++++++++++++++
>From <jcushing@grove.ufl.edu>
Date: Mon, 4 Nov 1996 11:50:56 -0500
Organization: University of Florida
On 3 Nov 1996, Jim Merkel wrote:
> raterwil@ucla.edu (Robert Terwilliger) wrote:
>
> >I am trying to display a pixmap on a mac screen. I can't get it to look
> >the way I want it to. It is a 128x128 pixel 8-bit grayscale MRI image
> >which appears fine when I display it on NIH image but I cannot get it to
> >display on my program. Does anyone have experience reading in raw data
> >files (not picts, tiffs or other preformatted files) and displaying them
> >on the screen?
> >
> >I do not know if I need to convert the image to 48-bit RGB before
> >displaying or what. If anyone can help me, please let me know. I can
> >forward you my code and explain exactly where the problem is.
> >
> >I am using Code Warrior 9 and program in C.
> >
> >Thank you.
> >
> >Robert Terwilliger
>
> The system grayscale color table (resource
> ID = 40) runs in the opposite direction. If you use it, you will probably
> get a negative of the image. In other words. you may have to make your own
> grayscale color table. You can do that in ResEdit (it's a pain but can be
> done).
>
> Jim Merkel
Couldn't hey also use the system grayscale table, then call InvertRect()?
This would avoid having to create a color table in ResEdit, or by other
means.
+++++++++++++++++++++++++++
>From jimmerkel@aol.com
Date: 5 Nov 1996 05:14:29 GMT
Organization: America Online, Inc. (1-800-827-6364) (1.10)
jcushing@grove.ufl.edu wrote:
>> The system grayscale color table (resource
>> ID = 40) runs in the opposite direction. If you use it, you will
probably
>> get a negative of the image. In other words. you may have to make your
own
>> grayscale color table. You can do that in ResEdit (it's a pain but can
be
>> done).
>>
>> Jim Merkel
>Couldn't hey also use the system grayscale table, then call InvertRect()?
>This would avoid having to create a color table in ResEdit, or by other
>means.
Yes, that's right. According to Inside Mac, for indexed color, Quickdraw
performs the inversion on the pixel indexes of the color table when you
call InvertRect(). Seems like there's always several ways to something on
the Mac.
Jim Merkel
---------------------------
>From andi@concentric.net (andi jones)
Subject: resedit & PICT resources: help
Date: 5 Nov 1996 05:47:30 GMT
Organization: angelwerks
i am posting this to .games, .tools and .help, hoping someone can give me
a hand.
i am trying to learn how to edit (and make) PICT resource files. i have
resedit (v.2.1.3) and have borrowed two books on the subject, and i have
had no luck. i am not a programmer, so all i can do is follow instructions
in the book. they do not work.
can anyone point me to some decent, detailed instructions on editting and
making PICT resources? does anyone maintain a FAQ, or have a site on the
web i can visit? is there a book out there that simply outlines this
stuff? i don't know if this is complicated to do or not, but i am eager to
learn. any help anyone can offer would be much appreciated.
thanks.
end of line.
+++++++++++++++++++++++++++
>From slur@world.std.com (Scott Lahteine)
Date: Wed, 6 Nov 1996 01:52:47 GMT
Organization: Hot Eggs
In article <andi-0511960047520001@206.173.7.37>, andi@concentric.net (andi
jones) wrote:
>i am posting this to .games, .tools and .help, hoping someone can give me
>a hand.
>
>i am trying to learn how to edit (and make) PICT resource files. i have
>resedit (v.2.1.3) and have borrowed two books on the subject, and i have
>had no luck. i am not a programmer, so all i can do is follow instructions
>in the book. they do not work.
>
Make a PICT by using any paint or image-editing program, save the
file as a .PICT, and use ResEdit to cut and paste the file's PICT resource
into your own.
--
- scott slur@world.std.com
"A painting of a rice cake does not satisfy hunger."
+++++++++++++++++++++++++++
>From Keith Wiley <keithw@wam.umd.edu>
Date: Thu, 7 Nov 1996 08:16:43 -0500
Organization: University of Maryland, College Park, MD
> i am trying to learn how to edit (and make) PICT resource files. i have
> resedit (v.2.1.3) and have borrowed two books on the subject, and i have
> had no luck. i am not a programmer, so all i can do is follow instructions
> in the book. they do not work.
>
> can anyone point me to some decent, detailed instructions on editting and
> making PICT resources? does anyone maintain a FAQ, or have a site on the
> web i can visit? is there a book out there that simply outlines this
> stuff? i don't know if this is complicated to do or not, but i am eager to
> learn. any help anyone can offer would be much appreciated.
Use any paint program and paint the picture. Select it and copy it. Go
the ResEdit and make a new pict resource. Open the blank resource and
paste in you picture. Voila.
. . .. ... ..... ........ ............. .....................
.. ... ..... ....... ........... ............. .................
. .. .... ........ ................ ................................
Keith Wiley, Electrogenetic Engineer *
University of Maryland at College Park * * * * * *
email: keithw@wam.umd.edu *** ** * * ** *
world wide web: http://www.wam.umd.edu/~keithw * ** ** ***
+++++++++++++++++++++++++++
>From m_denny@cs.utas.edu.au (Marcus Denny)
Date: Wed, 06 Nov 1996 12:43:14 +1000
Organization: University of Tasmania
In article <andi-0511960047520001@206.173.7.37>, andi@concentric.net (andi
jones) wrote:
> can anyone point me to some decent, detailed instructions on editting and
> making PICT resources? does anyone maintain a FAQ, or have a site on the
> web i can visit? is there a book out there that simply outlines this
> stuff? i don't know if this is complicated to do or not, but i am eager to
> learn. any help anyone can offer would be much appreciated.
Editing PICT resources is not too complicated - even SimpleText can cut
and paste selections of a PICT resource. You might want to try working
with ClarisWorks Draw or some other application like that to actually
create and edit PICTs. ResEdit is useful if you want to change PICT
resources in applications (eg. change a spaceship picture in a game).
Usual disclaimers about ResEdit - don't use it unless you know what you're
doing.
You can mail me if you want some more specific info.
Cheers,
Marcus
m_denny@cs.utas.edu.au
---------------------------
End of C.S.M.P. Digest
**********************